home *** CD-ROM | disk | FTP | other *** search
/ Info-Mac 4 / Info_Mac IV CD-ROM (Pacific HiTech Inc.)(August 1994).iso / Applications / ProGen Demo / TEMPLATE.SCR < prev    next >
Text File  |  1994-02-18  |  3KB  |  106 lines

  1. ;; **** Main Procedures ****
  2.  
  3. PROCEDURE ("Startup")
  4.     Dialog(dlgAbout,3)
  5.   do("Main")
  6. ENDPROC
  7.  
  8.  
  9. PROCEDURE ("ABOUT")
  10.   Dialog(dlgAbout)
  11. ENDPROC
  12.  
  13.  
  14. PROCEDURE ("Main")
  15.   Set(platform,"M")
  16.   Set(productType,"")
  17.   Set(userName,"GenSoft")
  18.   Set(companyName,"GenSoft")
  19.   Set(serialNumber,"7MRSIE 25M 168905 03655")
  20.   Set(startup,"S")
  21.   Set(fileMask,"PG$$APPL")
  22.   Set(destination,"%D")
  23.   
  24.   Dialog(dlgMain)
  25.   on (open)
  26.       SetDlgItemText(TITLE,"ProGen Installation") ;; main window title
  27.       SetDlgItemText(1,"Install ProGen Demonstration to your Hard Disk.")
  28. ;;  Hide pushbuttons 2-4
  29.       HideDlgItem(7)
  30.       HideDlgItem(8)
  31.       HideDlgItem(9)
  32.   on (install)
  33.       do("Install")
  34.   on (quit)
  35.       quit
  36. ENDPROC
  37.  
  38. ;; **** Install Procedures ****
  39.  
  40. PROCEDURE ("Install")
  41.   Dialog(dlgInstall)
  42.   on (open)
  43.       SetDlgItemText(TITLE,"Install ProGen")
  44.       SetDlgItemText(24,"Name a NEW directory in which to install ProGen.")
  45.       ;; AddCheckbox(chk1," YOUR TEXT ")
  46.       ;; AddCheckbox(chk2," YOUR TEXT ")
  47.       ;; AddCheckbox(chk3," YOUR TEXT ")
  48.       ;; SetDlgItemValue(chk1,1)
  49.       ;; SetDlgItemValue(chk2,1)
  50.       ;; SetDlgItemValue(chk3,1)
  51.       SetDlgItemText(13,"ProGen Demo")
  52.       do ("Set SpaceRequired",MD)
  53.   on (chk1,chk2,chk3)
  54.       do ("Set SpaceRequired",MD)
  55.   on (ok)
  56.       ;;do("Serialise")
  57.       WorkingMessage
  58.       do("Unpack Files")
  59.       CloseWorkingMessage
  60.   on (cancel)
  61.       Set(destination,"%D")
  62.       Delete("",ignoreError)
  63.   on (error)
  64.       Message("Due to an error, the installation is aborted. All files installed so far will be removed")
  65.       do ("Delete Files")
  66.   on (break)
  67.       Message("Aborting installation. All files installed so far will be removed")
  68.       do ("Delete Files")
  69. ENDPROC
  70.  
  71.  
  72. PROCEDURE ("Serialise")
  73.   Dialog(dlgSerial)
  74.   ON(open)
  75.       ; Set Company Name Text Field
  76.       Set(companyName,"GenSoft")
  77.       SetDlgItemText(7,"GenSoft")
  78.       HideDlgItem(11)
  79.       HideDlgItem(7)
  80.       ; Hide Radio Button for startup mode - will always be single user.
  81.       HideDlgItem(3)
  82.       HideDlgItem(4)
  83.       HideDlgItem(5)
  84.       SetDlgItemValue(4,1)
  85.       ; User Instructions Text
  86.       SetDlgItemText(9,"Enter your name and serial number, from your registration card. Register with GenSoft for product support.")
  87.       
  88.   ON(ok)
  89.       WorkingMessage
  90.       do("Unpack Files")
  91.       CloseWorkingMessage
  92. ENDPROC
  93.  
  94.  
  95. ;; **** General Routines used by Install & Update ****
  96. ;;
  97. ;; Three routines will be appended here by the Make Masters command.
  98. ;;
  99. ;; 1) "Unpack Files" which contains all commands to unpack files or create directories.
  100. ;; 2) "Delete Files" which removes files and directories if an error occurs during an
  101. ;;    Instalation.
  102. ;; 3) "Set SpaceRequired" which gets called by Install and Update to set the correct
  103. ;;    space required, for the files about to be installed.
  104.  
  105.  
  106.